<?php
namespace app\home\controller;

use think\Controller;
use think\Session;
use think\Request;
use app\home\model\SearchModel;

class Search extends Controller
{
	/**
	*	搜索功能
	*/
	public function search()
	{
		$data = $this->request->param();

		$SearchModel = new SearchModel();

		$list = $SearchModel->getSearch($data);
		
		$this->assign('list',$list);		

		$this->assign('keyword',isset($data['keyword']) ? $data['keyword'] : '');
		
		return $this->fetch();
	}
}